/*
 * Copyright (c) Huawei Technologies Co., Ltd. 2022-2022. All rights reserved.
 * Description: 集合通信算子lowering
 * Author: lilianlin
 * Create: 2022-07-15
 */
#ifndef HCOM_NODE_CONVERTER_H
#define HCOM_NODE_CONVERTER_H
#include "register/node_converter_registry.h"
#include "base.h"

namespace hccl {
gert::LowerResult LoweringHcomNode(const ge::NodePtr &node, const gert::LowerInput &lowerInput);
gert::LowerResult LoweringAlltoAllNode(const ge::NodePtr &node, const gert::LowerInput &lowerInput);
gert::LowerResult LoweringRemoteNode(const ge::NodePtr &node, const gert::LowerInput &lowerInput);
gert::LowerResult LoweringRecvNode(const ge::NodePtr &node, const gert::LowerInput &lowerInput);

gert::bg::DevMemValueHolderPtr MakeSureInputAtHost(const ge::NodePtr &node, const gert::LowerInput &lowerInput,
    u32 index);
std::vector<gert::bg::DevMemValueHolderPtr> MakeSureCommAlltoAllInput(const ge::NodePtr &node,
    const gert::LowerInput &lower_input);

gert::LowerResult LoweringRecvNode(const ge::NodePtr &node, const gert::LowerInput &lowerInput);
} // namespace hccl
#endif // HCOM_NODE_CONVERTER_H